home *** CD-ROM | disk | FTP | other *** search
/ Mac-Source 1994 July / Mac-Source_July_1994.iso / C and C++ / Libraries / SAT / HeartQuest sample ƒ / SoundConst.p < prev    next >
Encoding:
Text File  |  1993-08-18  |  1.6 KB  |  55 lines  |  [TEXT/PJMM]

  1. {=================================================}
  2. {============= Sound Constants and handles ==============}
  3. {=================================================}
  4.  
  5. { Example file for Ingemars Sprite Animation Toolkit. }
  6. { © Ingemar Ragnemalm 1992 }
  7. { See doc files for legal terms for using this code. }
  8.  
  9. { This file defines all the resource numbers for your sound resources, plus}
  10. { handles to each one. The procedure LoadSounds is called at startup. It calls}
  11. { the sound units for each sound to preload. Note that merely loading the sound}
  12. { is not enough if the sound units decide to use Sound Driver. }
  13.  
  14. { When designing your game, my advice to you is to use sounds, several sounds,}
  15. { but not ridiculously many and large. A simplistic game that takes 1000k on disk}
  16. { just because it contains lots of sounds is just a waste of disk (and we have seen}
  17. { far too many of them on the shareware market), but a well-polished, complex}
  18. { and interesting game can use more. }
  19.  
  20. unit SoundConst;
  21.  
  22. interface
  23.  
  24.     uses
  25.         SAT;
  26.  
  27.     const
  28.         Splatt2Snd = 14315;
  29.         Splatt3Snd = 20039;
  30.         KlounkSnd = 21999;
  31.         plinkSnd = 10873;
  32.         sadarSnd = 25626;
  33.         jaSnd = 3024;
  34.  
  35.  
  36.     var
  37.         Splatt2SndH, Splatt3SndH, KlounkSndH: handle;
  38.         plinkSndH, sadarSndH, jaSndH, TickSndH: handle;
  39.  
  40.     procedure loadsounds;
  41.  
  42. implementation
  43.  
  44.     procedure loadsounds;
  45.     begin
  46.         Splatt2SndH := SATGetSound(Splatt2Snd);
  47.         Splatt3SndH := SATGetSound(Splatt3Snd);
  48.         KlounkSndH := SATGetSound(KlounkSnd);
  49.         PlinkSndH := SATGetSound(PlinkSnd);
  50.         SadarSndH := SATGetSound(SadarSnd);
  51.         JaSndH := SATGetSound(JaSnd);
  52.         TickSndH := SATGetNamedSound('tick');
  53.     end;
  54.  
  55. end.